#ifndef __RESOURCEEDITORW_H_
#define __RESOURCEEDITORW_H_

#include <QWidget>

class ResourceEditorW : public QWidget
{
    Q_OBJECT
    Q_CLASSINFO("ClassID", "{87fd62df-8663-4195-a51e-75449f258262}")
    Q_CLASSINFO("InterfaceID", "{7bad53d4-9d28-4c08-bb7f-7219cbb63d68}")
    Q_CLASSINFO("EventsID", "{8404cd3d-41e2-4660-953f-4a4a59c69c93}")
    Q_CLASSINFO("ToSuperClass", "ResourceEditorW")

public:
    ResourceEditorW(QWidget *parent = 0);
    ~ResourceEditorW();

    QSize minimumSize();

    static ResourceEditorW *instance();

public Q_SLOTS:
    QString pluginFailureString() const;
    void updateResources(const QString &sourcePaths);
    bool initializeJambiPlugins(const QString &jambiBase, const QString &jambiPluginPath, const QString &customWidgetClassPath, const QString &resourcePath, const QString &jvm);
    void initialize();
    void updateCustomWidgetLocation(const QString &path);

protected:
    void resizeEvent(QResizeEvent *event);

private:
    QWidget *m_editor;
    uint m_initialized : 1;
    static ResourceEditorW *m_self;
};

#endif //__RESOURCEEDITORW_H_
